laravel route multiple methods

34

$router->get('/{home?}', 'SiteController@home')
       ->where('home', '(home|another_home_route)')
       ->name('home');
Route::match(['get', 'post'], '/user', [
    'uses' => 'AppController@user',
    'as'   => 'useraccess',
    'roles'=> 'HomeController@useroles', 
]);

Comments

Submit
0 Comments